// components/list/list.js
Component({
  /**
   * 组件的属性列表
   */
  properties: {
    list: {
      type: Array
    },
    type: {
      type: String
    }
  },

  /**
   * 组件的初始数据
   */
  data: {

  },

  /**
   * 组件的方法列表
   */
  methods: {
    enterDetail(e){
      let id = e.currentTarget.dataset.id;
      let type = e.currentTarget.dataset.type;
      let url;
      console.log(id,type)
      if(type=='rulesDetail'){
        url = '/pages/rule/rulesDetail/rulesDetail?id='+id;
      }else if(type=='other'||type=="search"){
        url = '/pages/rule/other/otherDetail?id=' + id;
      }else if(type=='notice'){
        url = '/pages/notice/notice?id=' + id;
      }
      wx.navigateTo({
        url: url,
      })
    }
  }
})
